package spring.in.action.chapter_03.conditional;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Conditional;
import org.springframework.context.annotation.Configuration;

@Configuration
public class MagicConfig
{
    @Bean
    @Conditional(MagicExistsCondition.class)
    public MagicBean magicBean()
    {
        System.out.println("new MagicBean");
        return new MagicBean();
    }
}
